/*
 * Author: Liviu Patrasco
 * TCSS 342 Winter qrt
 * May 22, 2011
 * Scheduler-svn
 * 
 * ChangeLog:
 * 5/26/2011 - Matt added to constructor and added the addTimePref() method.
 */
package main;

import java.util.ArrayList;
import java.util.List;

/**
 * Student class.
 * <br><br>
 * @author Liviu Patrasco
 * @author Matthew Smith - additions are listed in the ChangeLog.
 * @version May 22, 2011
 */
public class Student extends DataUser{
	
	private List<TimeBlock> my_timePrefs;
	
	
	/**
	 * Constructor.
	 */
	public Student(String the_userName, String the_pswrd) {
		super(the_userName, the_pswrd);
		my_timePrefs = new ArrayList<TimeBlock>();
	}
	
	/**
	 * Adds a time preference to this Student. Start and end times are Strings
	 * containing a time in military format (ex. "1430" would be 2:30 PM). The days
	 * of the week is a String where each letter corresponds to a single day of the week
	 * and are listed in order (ex. "MWF" means Monday, Wednesday, and Friday).
	 * 
	 * @param the_start_time The start of the block of time.
	 * @param the_end_time The end of the block of time.
	 * @param the_days The days of the week of the block of time.
	 */
	public void addTimePref(final String the_start_time, final String the_end_time,
			final String the_days) {
		my_timePrefs.add(new TimeBlock(the_start_time, the_end_time, the_days));
	}
	
	/**
	 * Sets Time prefs.
	 */
	public void setTimePrefs(List<TimeBlock> my_timePrefs) {
		this.my_timePrefs = my_timePrefs;
	}

	/**
	 * @return the Time prefs
	 */
	public List<TimeBlock> getTimePrefs() {
		return my_timePrefs;
	}

}
